package com.kotlin.heimaplayer.presenter.impl

import com.kotlin.heimaplayer.model.CommonResultBean
import com.kotlin.heimaplayer.model.MvAreaBean
import com.kotlin.heimaplayer.net.MvAreaRequest
import com.kotlin.heimaplayer.net.ResponseHandler
import com.kotlin.heimaplayer.presenter.interf.MvPresenter
import com.kotlin.heimaplayer.view.MvView

class MvPresenterImpl(var mvView: MvView):MvPresenter, ResponseHandler<CommonResultBean<MvAreaBean>> {
    override fun onError(type: Int, msg: String?) {
        mvView.onError(msg)
    }

    override fun onSuccess(type: Int, result: CommonResultBean<MvAreaBean>) {
        mvView.onSuccess(result)
    }

    override fun loadDatas() {
        MvAreaRequest(this).excute()
    }
}